package two;

/**
 * @Author:DarknessShadow
 * @description:
 * @date 2020/5/12 10:39
 */
public class Main2 extends Thread {

    public static void main(String[] args) {
        System.out.println("start.....");
        for (int i = 0; i < 1000; i++) {
            new Main2(String.valueOf(i)).start();
        }
        System.out.println("end......");
    }

    public void run() {
        Singleton2 singleton2 = Singleton2.getInstance();
        System.out.println(getName() + ": obj = "  + singleton2);
    }

    public Main2(String name) {
        super(name);
    }
}
